#!/bin/sh

############################################
##                WARNING                 ##
############################################
## use this file only for package builds  ##
############################################

PREFIX=$1
VER=0.9.2

if [ -z "${PREFIX}" ] ; then
	PREFIX=/usr/local/openca.${VER}
fi

./configure \
  --prefix=${PREFIX} \
  --with-openca-prefix=${PREFIX}/openca \
  --with-etc-prefix=${PREFIX}/openca/etc \
  --with-httpd-fs-prefix=${PREFIX}/httpd \
  --with-module-prefix=${PREFIX}/modules \
  --with-openssl-prefix=/usr/local/ssl \
  --with-engine=no \
  --with-web-host="localhost.localdomain" \
  --with-ca-organization="OpenCA" \
  --with-ca-country=IT \
  --with-ca-locality=Modena \
  --with-ldap-port=389 \
  --with-ldap-root="cn=Manager,o=OpenCA,c=IT" \
  --with-ldap-root-pwd="openca" \
  --enable-ocspd \
  --enable-db \
  --disable-dbi \
  --disable-rbac \
  --with-service-mail-account="root@localdomain" \
  --with-httpd-user=httpd \
  --with-httpd-group=nobody \
  --with-openca-user=root \
  --with-openca-group=nobody \
  --with-dist-user=madwolf \
  --with-dist-group=openca \
  --with-hierarchy-level=ca \
  --enable-package-build

